← Index
NYTProf Performance Profile   
For ../prof.pl
  Run on Wed Dec 14 15:33:55 2022
Reported on Wed Dec 14 15:40:04 2022

Filename(eval 433)[/Users/ether/.perlbrew/libs/36.0@std/lib/perl5/Sub/Quote.pm:3]
StatementsExecuted 54 statements in 1.23ms
Eval Invoked At/Users/ether/.perlbrew/libs/36.0@std/lib/perl5/Sub/Quote.pm line 3
Sibling evals1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
222218µs6.68msJSON::Schema::Modern::Result::::newJSON::Schema::Modern::Result::new
11176µs195µsJSON::Schema::Modern::Result::::BEGIN@13.338JSON::Schema::Modern::Result::BEGIN@13.338
11115µs44µsJSON::Schema::Modern::Result::::BEGIN@91JSON::Schema::Modern::Result::BEGIN@91
11114µs36µsJSON::Schema::Modern::Result::::BEGIN@54JSON::Schema::Modern::Result::BEGIN@54
11112µs12µsJSON::Schema::Modern::Result::::BEGIN@18.339JSON::Schema::Modern::Result::BEGIN@18.339
11111µs19µsJSON::Schema::Modern::Result::::BEGIN@59JSON::Schema::Modern::Result::BEGIN@59
11111µs17µsJSON::Schema::Modern::Result::::BEGIN@99JSON::Schema::Modern::Result::BEGIN@99
1118µs15µsJSON::Schema::Modern::Result::::BEGIN@83JSON::Schema::Modern::Result::BEGIN@83
1113µs9µsJSON::Schema::Modern::Result::::BEGIN@123JSON::Schema::Modern::Result::BEGIN@123
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1{
2219µs my $isa_check_for_formatted_5fannotations = ${$_[1]->{"\$isa_check_for_formatted_5fannotations"}};
310s my $_UNQUOTED = ${$_[1]->{"\$_UNQUOTED"}};
410s my $isa_check_for_exception = ${$_[1]->{"\$isa_check_for_exception"}};
510s my $isa_check_for_annotations = ${$_[1]->{"\$isa_check_for_annotations"}};
610s my $coerce_for_valid = ${$_[1]->{"\$coerce_for_valid"}};
710s my $isa_check_for_output_5fformat = ${$_[1]->{"\$isa_check_for_output_5fformat"}};
810s my $_QUOTED = ${$_[1]->{"\$_QUOTED"}};
910s my $isa_check_for_valid = ${$_[1]->{"\$isa_check_for_valid"}};
1010s my $coerce_for_exception = ${$_[1]->{"\$coerce_for_exception"}};
1110s my $isa_check_for_errors = ${$_[1]->{"\$isa_check_for_errors"}};
12 package JSON::Schema::Modern::Result;
13298µs2314µs
# spent 195µs (76+119) within JSON::Schema::Modern::Result::BEGIN@13.338 which was called: # once (76µs+119µs) by Sub::Quote::_clean_eval at line 13
no warnings 'closure';
# spent 195µs making 1 call to JSON::Schema::Modern::Result::BEGIN@13.338 # spent 119µs making 1 call to warnings::unimport
14
# spent 6.68ms (218µs+6.46) within JSON::Schema::Modern::Result::new which was called 2 times, avg 3.34ms/call: # once (124µs+6.37ms) by JSON::Schema::Modern::evaluate at line 382 of JSON/Schema/Modern.pm # once (94µs+97µs) by JSON::Schema::Modern::evaluate at line 177 of Sub/Defer.pm
sub new {
15 ($_QUOTED,$_UNQUOTED) if 0;
16# BEGIN quote_sub PRELUDE
17package JSON::Schema::Modern::Result;
18
# spent 12µs within JSON::Schema::Modern::Result::BEGIN@18.339 which was called: # once (12µs+0s) by Sub::Quote::_clean_eval at line 23
BEGIN {
1912µs $^H = 2018;
2010s ${^WARNING_BITS} = "UUUUUUUUUUUUUUUUUUUU";
2114µs %^H = (
22 );
231217µs112µs}
# spent 12µs making 1 call to JSON::Schema::Modern::Result::BEGIN@18.339
24# END quote_sub PRELUDE
2511µs my $invoker = CORE::shift();
2611µs my $class = CORE::ref($invoker) ? CORE::ref($invoker) : $invoker;
2710s if ($class ne "JSON::Schema::Modern::Result") {
28 if ($Moo::MAKERS{$class}) {
29 if ($Moo::MAKERS{$class}{constructor}) {
30 package JSON::Schema::Modern::Result;
31 return $invoker->SUPER::new(@_);
32 }
33 Moo->_constructor_maker_for($class);
34 return $invoker->new(@_);
35 } elsif ($INC{"Moose.pm"} and my $meta = Class::MOP::get_metaclass_by_name($class)) {
36 return $meta->new_object(
37 $class->can("BUILDARGS") ? $class->BUILDARGS(@_)
38 : $class->Moo::Object::BUILDARGS(@_)
39 );
40 }
41 }
42 my $args = scalar @_ == 1
43 ? CORE::ref $_[0] eq 'HASH'
4412µs ? { %{ $_[0] } }
45 : Carp::croak("Single parameters to new() must be a HASH ref"
46 . " data => ". $_[0])
47 : @_ % 2
48 ? Carp::croak("The new() method for $class expects a hash reference or a"
49 . " key/value list. You passed an odd number of arguments")
50 : {@_}
51 ;
5211µs my $new = bless({}, $class);;
53(exists $args->{"annotations"} and ($new->{"annotations"} = scalar do { my $value = $args->{"annotations"};
542217µs258µs
# spent 36µs (14+22) within JSON::Schema::Modern::Result::BEGIN@54 which was called: # once (14µs+22µs) by Sub::Quote::_clean_eval at line 54
(do { no warnings "void"; package Type::Tiny; (do { package Type::Tiny; (Ref::Util::XS::is_plain_arrayref($value)) and do { my $ok = 1; for my $i (@{$value}) { ($ok = 0, last) unless (Scalar::Util::blessed($i) and $i->isa(q[JSON::Schema::Modern::Annotation])) }; $ok } }) or Type::Tiny::_failed_check($isa_check_for_annotations, "ArrayRef[InstanceOf[\"JSON::Schema::Modern::Annotation\"]]", $value, "attribute_name","annotations","attribute_step","isa check","mgaca","0","varname","\$args->{\"annotations\"}"); $value }),
# spent 36µs making 1 call to JSON::Schema::Modern::Result::BEGIN@54 # spent 22µs making 1 call to warnings::unimport
55 $value
56}
57)),
58(exists $args->{"errors"} and ($new->{"errors"} = scalar do { my $value = $args->{"errors"};
592109µs227µs
# spent 19µs (11+8) within JSON::Schema::Modern::Result::BEGIN@59 which was called: # once (11µs+8µs) by Sub::Quote::_clean_eval at line 59
(do { no warnings "void"; package Type::Tiny; (do { package Type::Tiny; (Ref::Util::XS::is_plain_arrayref($value)) and do { my $ok = 1; for my $i (@{$value}) { ($ok = 0, last) unless (Scalar::Util::blessed($i) and $i->isa(q[JSON::Schema::Modern::Error])) }; $ok } }) or Type::Tiny::_failed_check($isa_check_for_errors, "ArrayRef[InstanceOf[\"JSON::Schema::Modern::Error\"]]", $value, "attribute_name","errors","attribute_step","isa check","mgaca","0","varname","\$args->{\"errors\"}"); $value }),
# spent 19µs making 1 call to JSON::Schema::Modern::Result::BEGIN@59 # spent 8µs making 1 call to warnings::unimport
60 $value
61}
62)),
63(exists $args->{"exception"} and ($new->{"exception"} = scalar do { my $value = do {
64 local $Method::Generate::Accessor::CurrentAttribute = {
65 init_arg => "exception",
66 name => "exception",
67 step => "coercion",
68 };
69 (my $_return),
70 (my $_error), (my $_old_error = $@);
71 (eval {
72 ($@ = $_old_error),
73 ($_return =
74$coerce_for_exception->($args->{"exception"})),
75 1
76 } or
77 $_error = CORE::ref $@ ? $@ : "coercion for \"exception\" failed: ".$@);
78 ($@ = $_old_error),
79 (defined $_error and CORE::die $_error);
80 $_return;
81}
82;
83267µs222µs
# spent 15µs (8+7) within JSON::Schema::Modern::Result::BEGIN@83 which was called: # once (8µs+7µs) by Sub::Quote::_clean_eval at line 83
(do { no warnings "void"; package Type::Tiny; ((Scalar::Util::blessed($value) and $value->isa(q[JSON::PP::Boolean]))) or Type::Tiny::_failed_check($isa_check_for_exception, "InstanceOf[\"JSON::PP::Boolean\"]", $value, "attribute_name","exception","attribute_step","isa check","mgaca","0","varname","\$args->{\"exception\"}"); $value }),
# spent 15µs making 1 call to JSON::Schema::Modern::Result::BEGIN@83 # spent 7µs making 1 call to warnings::unimport
84 $value
85}
86)),
87($new->{"formatted_annotations"} = scalar do { my $value = (
88 exists $args->{"formatted_annotations"}
8910s ? $args->{"formatted_annotations"}
90 : 1);
91590µs273µs
# spent 44µs (15+29) within JSON::Schema::Modern::Result::BEGIN@91 which was called: # once (15µs+29µs) by Sub::Quote::_clean_eval at line 91
(do { no warnings "void"; package Type::Tiny; ((!ref $value and (!defined $value or $value eq q() or $value eq '0' or $value eq '1'))) or Type::Tiny::_failed_check($isa_check_for_formatted_5fannotations, "Bool", $value, "attribute_name","formatted_annotations","attribute_step","isa check","mgaca","0","varname","\$args->{\"formatted_annotations\"}"); $value }),
# spent 44µs making 1 call to JSON::Schema::Modern::Result::BEGIN@91 # spent 29µs making 1 call to warnings::unimport
92 $value
93}
94),
95($new->{"output_format"} = scalar do { my $value = (
96 exists $args->{"output_format"}
9710s ? $args->{"output_format"}
98 : "basic");
995130µs325µs
# spent 17µs (11+6) within JSON::Schema::Modern::Result::BEGIN@99 which was called: # once (11µs+6µs) by Sub::Quote::_clean_eval at line 99
(do { no warnings "void"; package Type::Tiny; ((defined($value) and !ref($value) and $value =~ m{\A(?:(?:basic|detailed|flag|strict_basic|terse|verbose))\z})) or Type::Tiny::_failed_check($isa_check_for_output_5fformat, "Enum[\"flag\",\"basic\",\"strict_basic\",\"detailed\",\"verbose\",\"terse\"]", $value, "attribute_name","output_format","attribute_step","isa check","mgaca","0","varname","\$args->{\"output_format\"}"); $value }),
# spent 17µs making 1 call to JSON::Schema::Modern::Result::BEGIN@99 # spent 6µs making 1 call to warnings::unimport # spent 2µs making 1 call to Type::Tiny::CORE:match
100 $value
101}
102),
10310s(exists $args->{"valid"} and ($new->{"valid"} = scalar do { my $value = do {
104124µs local $Method::Generate::Accessor::CurrentAttribute = {
105 init_arg => "valid",
106 name => "valid",
107 step => "coercion",
108 };
10910s (my $_return),
110 (my $_error), (my $_old_error = $@);
11110s (eval {
112 ($@ = $_old_error),
113 ($_return =
11419µs164µs$coerce_for_valid->($args->{"valid"})),
115 1
116 } or
117 $_error = CORE::ref $@ ? $@ : "coercion for \"valid\" failed: ".$@);
11810s ($@ = $_old_error),
119 (defined $_error and CORE::die $_error);
12011µs $_return;
121}
122;
1235202µs417µs
# spent 9µs (3+6) within JSON::Schema::Modern::Result::BEGIN@123 which was called: # once (3µs+6µs) by Sub::Quote::_clean_eval at line 123
(do { no warnings "void"; package Type::Tiny; ((Scalar::Util::blessed($value) and $value->isa(q[JSON::PP::Boolean]))) or Type::Tiny::_failed_check($isa_check_for_valid, "InstanceOf[\"JSON::PP::Boolean\"]", $value, "attribute_name","valid","attribute_step","isa check","mgaca","0","varname","\$args->{\"valid\"}"); $value }),
# spent 9µs making 1 call to JSON::Schema::Modern::Result::BEGIN@123 # spent 6µs making 1 call to warnings::unimport # spent 1µs making 1 call to Scalar::Util::blessed # spent 1µs making 1 call to UNIVERSAL::isa
124 $value
125}
126)),
127 (($args)[0]->{__no_BUILD__} or (
128133µs129µs $new->JSON::Schema::Modern::Result::BUILD($args),
# spent 29µs making 1 call to JSON::Schema::Modern::Result::BUILD
129 )),
130 return $new;
131 }
13212µs $$_UNQUOTED = \&new;
133}
13416µs1;
135
136;